// 航次信息
<template>
  <div>
    <div class="voyage-info">
      <div class="voyage-info-item">
        <div class="address-info">
          <span class="iconfont icon-ship"></span>
          <span>始发港：</span>
          <span>{{ voyageInfo.departurePort }}</span>
        </div>
        <div class="time-info">
          {{ voyageInfo.voyageStartTime ? voyageInfo.voyageStartTime : "--" }}
        </div>
      </div>
      <div class="voyage-info-item">
        <div class="center-arrow">
          <span>{{ voyageInfo.shipVoyageStatus }}</span>
          <img src="@/assets/images/shipping-online/arrow-line.png" />
          <span>{{ voyageInfo.shipLoadStatus }}</span>
        </div>
      </div>

      <div class="voyage-info-item">
        <div class="address-info">
          <span class="iconfont icon-ship"></span>
          <span>目的港：</span>
          <span>{{ voyageInfo.destinationPort }}</span>
        </div>
        <div class="time-info">预：{{ voyageInfo.voyagePlanEndTime }}</div>
      </div>
    </div>
    <div class="goods-info">
      <div class="goods-info-item">
        <span class="iconfont icon-cargo"></span>
        <span>货物种类：{{ voyageInfo.cargoType }}</span>
      </div>
      <div class="goods-info-item">
        <span class="iconfont icon-cargo"></span>
        <span>货物重量：{{ voyageInfo.cargoWeight }} 吨</span>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  props: {
    voyageInfo: {
      type: Object,
    },
  },
};
</script>

<style lang="scss" scoped>
.goods-info {
  padding: 0 11px;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  margin-top: 19px;
  &-item {
    margin-right: 50px;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    span {
      font-size: 14px;
      font-weight: 400;
      color: #333333;
      &:first-child {
        margin-right: 8px;
        color: #004aaa;
      }
    }
  }
}
.voyage-info {
  //margin-top: 19px;
  padding: 0 11px;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  &-item {
    &:nth-child(2) {
      margin: 0 8px;
    }
    .address-info {
      margin-top: 16px;
      display: flex;
      justify-content: flex-start;
      align-items: center;
      font-size: 12px;
      font-weight: 400;
      color: #666666;
      span {
        &:first-child {
          color: #004aaa;
        }
        &:nth-child(2) {
          margin-left: 12px;
        }
        &:nth-child(3) {
          font-size: 14px;
          font-weight: 600;
        }
      }
    }
    .time-info {
      text-align: right;
      font-size: 12px;
      font-weight: 400;
      color: #666666;
    }
    .center-arrow {
      display: flex;
      flex-direction: column;
      justify-content: flex-start;
      align-items: center;

      font-size: 14px;
      font-weight: 400;
      color: #666666;
      img {
        width: 108px;
        height: 9px;
      }
    }
  }
}
</style>
